package com.moonshineproject.plugin.project.vo
{
	import flash.filesystem.File;
	
	public class ProjectVO extends FileWrapper
	{
		public function ProjectVO(file:File)
		{
			super(file);
		}
		
		public function get filePath():String
		{
			return (_file) ? file.nativePath : ""; 
		}
		public function set filePath(v:String):void
		{
			_file = new File(v);
		}
		
		public function saveSettings():void
		{
			
		}
		
		public function isFileIncludedInProject(file:File):Boolean
		{
			if (!file) return false;
			
			// If file is deeper than project root we assume it's in the project
			if (file.nativePath.indexOf(this.file.nativePath) == 0)
			{
				return true;
			}
			
			return false;
		}
	}
}